/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.dotexe.webframework.core.eventargs;

/**
 *
 * @author jovan.tomasevic
 */
public class RefreshStateArgs  {

        public String applicationName;

        public String holderID;
        /**
         Name of usecase to refresh
        */
        public String name ;
        /**
         Controller ElementId
        */
        public String controllerElementId;
        /**
         Id of usecase being refreshed
        */
        public String elementID;
        /**
         If control source is collection this value indicates id of current item
        */
        public Integer selectedItemId;
        /**
         Gets or sets the selected item ids if multiselection.
        */
        public long[] selectedItemIds;
        /**
         This is the value that changes data on the server
        */
        public Object value;
        /**
         Name of an event that is triggered
        */
        public String eventName;
        /**
         Name of client operation that is going to be executed
        */
        public String clientOperationName;
        /**
         Id of control that triggerd the refresh state
        */
        public String controlID;
        /**
         Type of UIControl triggerd the refresh state
        */
        public String controlType;
        /**
         Property name of data source item that is going to be updated
        */
        public String dataMemberName;
        /**
         Name of data source that is going to be updated
        */
        public String dataSourceName;
        /**
         Gets or sets a value indicating whether this instance is init request.
        */
        public Boolean isInit;




        public int requestId;

    public DataUpdateCollection dataUpdates;
    public RefreshStateArgs(){
        this.dataUpdates = new DataUpdateCollection();
    }
    @Override
    public  String toString()
    {
        return String.format("Name: %a, ElementID: %b, SelectedItemID: %c, Value: %d, EventName: %e, ClientOperationName: %f, ControlID: %g, ControlType: %h, DataMemberName: %i, DataSourceName: %j.",
                name, elementID, selectedItemId, value, eventName, clientOperationName, controlID, controlType, dataMemberName, dataSourceName);
    }
}
